<template>
  <van-tabs v-model:active="active" swipeable color="#fb7299" line-width="60px" line-height="4px">
    <div class="custom">
      <van-tab title="简介">
        <introduction :videoInfo="videoInfo" />
      </van-tab>
    </div>
    <div class="custom">
      <van-tab title="评论">
        <comments />
      </van-tab>
    </div>
  </van-tabs>
</template>
<script setup lang="ts">
import comments from '@/views/Video/components/video-comments.vue'
import introduction from '@/views/Video/components/video-introduction.vue'
import { Tabs as vanTabs, Tab as vanTab } from 'vant';
import { ref } from 'vue'

// 导入从 Video/index.vue 中获取的数据
import { defineProps, PropType } from 'vue'
import { IVideoInfo } from '../index.vue';

// 获取父组件 index.vue 中的数据
defineProps({
  videoInfo: {
    type: Object as PropType<IVideoInfo>,
  }
})

const active = ref(0)




</script>

<style lang="scss" scoped>
.custom {
  overflow: scroll;
  height: 47vh;
  margin-bottom: 40px;
}
</style>